<template>
  <div id="app">
    <router-view></router-view>
  </div>
</template>

<script>
import Footer from './views/components/Footer.vue';
// js
export default {
  components: {
    Footer
  },
  computed: {
    showFooter() {
      //定义需要显示底部导航栏的路由路径
      const allowedRoutes = ['/home/list', '/type', '/cart', '/my/center'];
      return allowedRoutes.includes(this.$route.path);
    }
  }

};
</script>

<style lang="less" scoped>
body {
  background:gray;
}
footer{
  background:#fff;
  height: 50px;
  position: fixed;
  width: 100%;
  bottom: 0;
}

</style>